package com.ruoyi.system.service.impl;

import java.util.List;

import com.ruoyi.common.annotation.AutoFill;
import com.ruoyi.common.enums.AutoFillType;
import com.ruoyi.common.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.system.mapper.DispatchPumpGroupOperationDataMapper;
import com.ruoyi.system.domain.DispatchPumpGroupOperationData;
import com.ruoyi.system.service.IDispatchPumpGroupOperationDataService;

/**
 * 泵组运行数据Service业务层处理
 * 
 * @author ruoyi
 * @date 2025-03-02
 */
@Service
public class DispatchPumpGroupOperationDataServiceImpl implements IDispatchPumpGroupOperationDataService 
{
    @Autowired
    private DispatchPumpGroupOperationDataMapper dispatchPumpGroupOperationDataMapper;

    /**
     * 查询泵组运行数据
     * 
     * @param pumpGroupOperationDataId 泵组运行数据主键
     * @return 泵组运行数据
     */
    @Override
    public DispatchPumpGroupOperationData selectDispatchPumpGroupOperationDataByPumpGroupOperationDataId(Long pumpGroupOperationDataId)
    {
        return dispatchPumpGroupOperationDataMapper.selectDispatchPumpGroupOperationDataByPumpGroupOperationDataId(pumpGroupOperationDataId);
    }

    /**
     * 查询泵组运行数据列表
     * 
     * @param dispatchPumpGroupOperationData 泵组运行数据
     * @return 泵组运行数据
     */
    @Override
    public List<DispatchPumpGroupOperationData> selectDispatchPumpGroupOperationDataList(DispatchPumpGroupOperationData dispatchPumpGroupOperationData)
    {
        return dispatchPumpGroupOperationDataMapper.selectDispatchPumpGroupOperationDataList(dispatchPumpGroupOperationData);
    }

    /**
     * 新增泵组运行数据
     * 
     * @param dispatchPumpGroupOperationData 泵组运行数据
     * @return 结果
     */
    @AutoFill(operation = AutoFillType.INSERT)
    @Override
    public int insertDispatchPumpGroupOperationData(DispatchPumpGroupOperationData dispatchPumpGroupOperationData)
    {
        return dispatchPumpGroupOperationDataMapper.insertDispatchPumpGroupOperationData(dispatchPumpGroupOperationData);
    }

    /**
     * 修改泵组运行数据
     * 
     * @param dispatchPumpGroupOperationData 泵组运行数据
     * @return 结果
     */
    @AutoFill(operation = AutoFillType.UPDATE)
    @Override
    public int updateDispatchPumpGroupOperationData(DispatchPumpGroupOperationData dispatchPumpGroupOperationData)
    {
        return dispatchPumpGroupOperationDataMapper.updateDispatchPumpGroupOperationData(dispatchPumpGroupOperationData);
    }

    /**
     * 批量删除泵组运行数据
     * 
     * @param pumpGroupOperationDataIds 需要删除的泵组运行数据主键
     * @return 结果
     */
    @Override
    public int deleteDispatchPumpGroupOperationDataByPumpGroupOperationDataIds(Long[] pumpGroupOperationDataIds)
    {
        return dispatchPumpGroupOperationDataMapper.deleteDispatchPumpGroupOperationDataByPumpGroupOperationDataIds(pumpGroupOperationDataIds);
    }

    /**
     * 删除泵组运行数据信息
     * 
     * @param pumpGroupOperationDataId 泵组运行数据主键
     * @return 结果
     */
    @Override
    public int deleteDispatchPumpGroupOperationDataByPumpGroupOperationDataId(Long pumpGroupOperationDataId)
    {
        return dispatchPumpGroupOperationDataMapper.deleteDispatchPumpGroupOperationDataByPumpGroupOperationDataId(pumpGroupOperationDataId);
    }
}
